﻿
using AutoMapper;
using Domain.Entity;
using Domain.IRepository;
using Domain.Repository;

namespace AppService.CMService
{
    public class CMService : ICMService
	{
        private readonly IMapper mapper;
        public ICMRepository CMRepository { get; set; }
		

		public CMService(IMapper mapper, ICMRepository CMRepository)
        {
            this.mapper = mapper;
            this.CMRepository = CMRepository;

		}

        public List<CM> GetCM()
        {
            return CMRepository.GetCM();
        }

        public Task<int> DeleteCM(int id)
        {
            return CMRepository.DeleteCM(id);
        }
    }
}
